Skip to main content

All Questions

Tagged with
0votes
0answers
391views

Open GUI linux terminal in non-interactive mode

It would be helpful if I can open a terminal and run commands exactly as if they would be run by a non-interactive bash script, to test whether certain commands work in non-interactive mode without ...
user56834's user avatar
0votes
1answer
90views

Is there any way to permanently have shell aliases on an imutable system

I'm on blendOS https://blendos.co/ which is an immutable operating system which means I cant just add a file to /bin/ like you would do normally to add a custom command right now I'm keeping it simple ...
HunterLyre's user avatar
0votes
0answers
171views

How can I add a line to file using bitbucket pipeline build

I have made a bitbucket pipeline, but I want to make changes to configuration file each time during after its build I want to add "Staging" each time after the build of the project to a ...
oo7hacker's user avatar
2votes
1answer
283views

Unexpected `^[[I` shows up when running vim script from command line

In a shell script, if I source even a trivial vim script this way $ cat ascript :q $ cat test vim -S ascript -N -u NONE read This is what I get when I run it: $ bash test ^[[I The ^[[I output is ...
Tagwint's user avatar
  • 2,500
-2votes
1answer
793views

How to remove query parameters from file extensions? [duplicate]

How to remove query parameters from file extensions i have downloaded 260 000 image files, which look like this: filename.jpg? filename2.jpg? filename3.jpg? how can i easily rename/remove the ...
Matthew Swart's user avatar
0votes
0answers
996views

Welcome message in the terminal

I'm trying to create a script that shows a welcome message when the root user enters the terminal. My current problem is that the welcome message also gets shown if a normal user starts the terminal......
Front Kick's user avatar
1vote
1answer
2kviews

Bash script for plotting multiple files with Gnuplot

I want to plot several files just executing a bash script which calls Gnuplot. My idea of a possible bash script is: #!/bin/bash gnuplot plot 'my_first_file.dat' u 1:2 replot 'my_second_file.dat' u 1:...
Siderius's user avatar
0votes
0answers
186views

Arguments to change awk variables

Newbie at Bash Scripting. List of Data: Filename has date included "0310_Filename" Hour AM/PM Game 1 Game2 Game 3 12:00:00 AM First Last First Last First Last I am ...
Eric's user avatar
3votes
5answers
461views

Swap positions of two consecutive lines exhibiting a common string

I have a text file with approx. 12 millions of lines, each composed of 4 fields (column 1, 2, 3 and 4) Most lines have a unique STRING in column 2. I don't want to modify any of these lines. Spread in ...
Opus_francigenum's user avatar
0votes
1answer
256views

Terminal window title vs Git branch name in the command prompt?

I wanted to add information about Git branch to my command line prompt, and I found this post: parse_git_branch() { git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' } export ...
Danijel's user avatar
0votes
1answer
1kviews

How to add a text file into a bash script then work with that text file

I need to read into my script 3 parameters, the first 2 are numbers and the third one is a .txt file. For example: example.sh 3 2 exam.txt And with the third parameter exam.txt that already has some ...
Zijad Bećirević's user avatar
1vote
1answer
84views

(perl) Rename bulk files - moving section starting with #{NUMBER} to front

I am trying to rename many files with the example formatting using rename with perl scripting 'Balisong Tutorial - (0g Chaplin) - Advanced #21-d8ajkHL34s0.mkv' 'Balisong Tutorial - (ALT Reverse Behind ...
Shawn's user avatar
1vote
0answers
96views

Changing the Creation/Modification Dates of Nested Folders

I have 1,000,000 .mp4 files in a single folder (Mac) and was looking for some code that would move the files into dated folders based on their creation/modified dates (they are the same). @pLumo came ...
macuseronline's user avatar
1vote
2answers
364views

Get terminal status for termcap capabilities

How can one retrieve status of terminal settings like smam and rmam ? Reason is that I set rmam by: tput rmam in script, then proceed to set smam on exit: tput smam But if terminal has rmam set when ...
ibuprofen's user avatar
1vote
1answer
64views

why are /etc/rc.d/rcx.d files empty

As I was trying to find which services get started at each run level, I run ls -l /etc/rc.d/rcx.d and even manually browsed and open the files. But there seems to be nothing in there. Is this ordinary ...
Am ine's user avatar

153050per page
close